﻿CREATE PROCEDURE [dbo].[DepartmentOptionsUpdate]
(
	@Note varchar(250),
	@MD datetime,
	@MW varchar(50),
	@Original_DepartmentId int,
	@Original_MD datetime
)
AS
	SET NOCOUNT OFF;
UPDATE PR.DepartmentOptions SET [Note] = @Note, [MD] = @MD, [MW] = @MW 
WHERE DepartmentId = @Original_DepartmentId AND MD = @Original_MD;
	
SELECT DepartmentId, NextBarCode, Note, MD, MW 
FROM PR.DepartmentOptions WHERE DepartmentId = @Original_DepartmentId

